php forum
php mysql forum
php mysql smarty
 
Page 1 of 2 1 2 >
Topic Options
#263942 - 12/06/03 11:23 AM Beta-[6.5] Photopost Information in Post Screens 2.0
scroungr Offline
Old Hand

Registered: 10/17/03
Posts: 2409
Loc: Richmond, VA
Description: Adds links in showflat and showthreaded view screens undeneath the user's avatar that point to their gallery in PhotoPost. If the user doesn't have any photos the link does not appear. Also the same thing happens in the showprofile screen <br /> <br />Working Under: UBB.Threads 6.5 thru 6.3 See Version 1 <br /> <br />Mod Status: Beta <br /> <br />Any pre-requisites: UBB Threads 6.3/6.4/6.5 and PhotoPost 4.0/4.8 <br /> <br />Author(s): dimopoulos <br /> <br />Date: 08/26/03 <br /> <br />Credits: Ian_W for suggesting it, scroungr for updating to work with 6.5 <br /> <br />Files Altered: showflat.php, showthreaded.php, showprofile.php, config.inc.php, templates/default/showflat.php, templates/default/showthreaded.php, templates/default/showprofile.php, languages/.../generic.php <br /> <br />New Files: fileiconphoto.gif <br /> <br />Database Altered: No <br /> <br />Info/Instructions: Fairly easy modification. I have not tried this in previous versions of UBBThreads or Photopost but I don't see why it shouldn't work.


Attachments
101223-[6.5]PhotopostInfoInPostScreens.zip (99 downloads)



Edited by scroungr (08/09/04 08:49 AM)

Top
#263943 - 12/06/03 12:00 PM Re: Beta-[6.4] Photopost Information in Post Screens 2.0 [Re: 234234]
omegatron Offline
Member

Registered: 04/05/01
Posts: 3440
Loc: abingdon,md
Great Work Scroungr <img src="http://www.ubbdev.com/forum/images/graemlins/wink.gif" alt="" /> I think many Photopost users will be happy.


Edited by Ian_W (12/07/03 06:54 AM)
_________________________
Chuck S

DIVE IN AND VISIT ME:

Omegatron\'s Reefs

Administrator at ReefTalk

Top
#263944 - 01/15/04 01:44 PM Re: Beta-[6.4] Photopost Information in Post Screens 2.0 [Re: sf49rminer]
scroungr Offline
Old Hand

Registered: 10/17/03
Posts: 2409
Loc: Richmond, VA
Got one problem with this one. Seems with Josh's spider mod it throws no error but doesn't know where to go ...<br /><br />ie http://www.couch-tomatoe.cc/ubbthreads/s...ry.php?ppuser=9<br /><br />but should go to http://www.couch-tomatoe.cc/photopost/showgallery.php?ppuser=9
_________________________
Couchtomatoe - www.couch-tomatoe.cc
My abilities are for hire for installs, upgrades, custom themes and custom modifications.

Top
#263945 - 01/15/04 02:00 PM Re: Beta-[6.4] Photopost Information in Post Screens 2.0 [Re: 234234]
JoshPet Offline
I type Like navaho

Registered: 11/29/01
Posts: 11330
Loc: Charlotte, NC
Ugh..<br /><br />I also answered this via PM - which I'd copied and pasted my answer here for everyone.<br /><br />Since the spider mod fools the variables into looking like direcotry names, you can't use a relative url for the link <a href="../photopost/showgallery.php?ppuser=23"><br /><br />You have to use a complete url like this:<br /><br /><a href="www.whatever.com/photopost/showgallery.php?ppuser=23"><br /><br /><img src="http://www.ubbdev.com/forum/images/graemlins/wink.gif" alt="" /><br /><br />I haven't used this mod, but it looks like the ".." part is configurable in the config file. <img src="http://www.ubbdev.com/forum/images/graemlins/smile.gif" alt="" />
_________________________
Joshua Pettit
www.JoshuaPettit.com
My abilities are for hire.

Top
#263946 - 01/15/04 02:38 PM Re: Beta-[6.4] Photopost Information in Post Screens 2.0 [Re: Daine]
scroungr Offline
Old Hand

Registered: 10/17/03
Posts: 2409
Loc: Richmond, VA
yeah just found that before coming back here and your correct I had a relative in there so I killed it.. hope it wasn't someone too close to me <img src="http://www.ubbdev.com/forum/images/graemlins/smile.gif" alt="" /> thanx <img src="http://www.ubbdev.com/forum/images/graemlins/smile.gif" alt="" />
_________________________
Couchtomatoe - www.couch-tomatoe.cc
My abilities are for hire for installs, upgrades, custom themes and custom modifications.

Top
#263947 - 01/15/04 02:41 PM Re: Beta-[6.4] Photopost Information in Post Screens 2.0 [Re: 234234]
scroungr Offline
Old Hand

Registered: 10/17/03
Posts: 2409
Loc: Richmond, VA
okay one more thing with this mod the line in showprofile you see will fill up fast so you can put a <br> before it in the showprofile.php and then in showprofile.tmpl take out the <br> you see after it..
_________________________
Couchtomatoe - www.couch-tomatoe.cc
My abilities are for hire for installs, upgrades, custom themes and custom modifications.

Top
#263948 - 07/04/04 01:39 AM Re: Beta-[6.4] Photopost Information in Post Screens 2.0 [Re: 234234]
donJulio Offline
Code Monkey

Registered: 06/17/02
Posts: 682
Loc: CA, USA
Will this work for 6.5? Or should I wait for an update?
_________________________
Too many men. There's too many people making too many problems, and not much love to go around. Can't you see this is the Land of Confusion? <img src="http://www.ubbdev.com/forum/images/graemlins/confused.gif" alt="" />

Top
#263949 - 07/04/04 10:54 AM Re: Beta-[6.4] Photopost Information in Post Screens 2.0 [Re: luan]
scroungr Offline
Old Hand

Registered: 10/17/03
Posts: 2409
Loc: Richmond, VA
should work. I did it with no problems
_________________________
Couchtomatoe - www.couch-tomatoe.cc
My abilities are for hire for installs, upgrades, custom themes and custom modifications.

Top
#263950 - 07/04/04 11:17 AM Re: Beta-[6.4] Photopost Information in Post Screens 2.0 [Re: 234234]
donJulio Offline
Code Monkey

Registered: 06/17/02
Posts: 682
Loc: CA, USA
Thanks scroungr! <img src="http://www.ubbdev.com/forum/images/graemlins/laugh.gif" alt="" /> This is one of my favorite mods right here!
_________________________
Too many men. There's too many people making too many problems, and not much love to go around. Can't you see this is the Land of Confusion? <img src="http://www.ubbdev.com/forum/images/graemlins/confused.gif" alt="" />

Top
#263951 - 07/04/04 01:31 PM Re: Beta-[6.5] Photopost Information in Post Screens 2.0 [Re: 234234]
scroungr Offline
Old Hand

Registered: 10/17/03
Posts: 2409
Loc: Richmond, VA
reflects working in 6.5
_________________________
Couchtomatoe - www.couch-tomatoe.cc
My abilities are for hire for installs, upgrades, custom themes and custom modifications.

Top
#263952 - 08/08/04 12:16 PM Re: Beta-[6.5] Photopost Information in Post Screens 2.0 [Re: 234234]
monkeyra Offline
Junior Member

Registered: 06/28/01
Posts: 363
Loc: uk
Got a problem!<br />Could not connect to PhotoPost databaseNo Database Selected<br />But, I know there is.<br />I've checked the config.inc.php file and the settings to my photopost databse are correct.<br />ideas peeps?

Top
#263953 - 08/08/04 12:23 PM Re: Beta-[6.5] Photopost Information in Post Screens 2.0 [Re: Luka_dup1]
monkeyra Offline
Junior Member

Registered: 06/28/01
Posts: 363
Loc: uk
dur, i'm so dumb, ignore that first error (i edited an old config.inc.php, i should clear out my files!!)<br />but i have got a new error<br /><br />Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/fordmond/public_html/ubbthreads/showflat.php on line 699<br /><br />Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/fordmond/public_html/ubbthreads/showflat.php on line 703<br /><br />which focuses on this bit:<br /><br />// We need to know how many posts of this thread to display per page<br />if ($fpart <= 1) {<br /> $Totalgrab = $Totaldisplay;<br />}<br />else {<br /> $Startat = $Totaldisplay * ($fpart - 1);<br /> $Totalgrab = "$Startat, $Totaldisplay";<br />}<br />$Limit = "LIMIT $Totalgrab";<br />if ($fpart == "all") {<br /> $Limit = "";<br />}<br /><br /><br /><br />you might be able to spot the two } which i made bold, that seems to tbe the problem <img src="http://www.ubbdev.com/forum/images/graemlins/confused.gif" alt="" />

Top
#263954 - 08/08/04 03:47 PM Re: Beta-[6.5] Photopost Information in Post Screens 2.0 [Re: Luka_dup1]
scroungr Offline
Old Hand

Registered: 10/17/03
Posts: 2409
Loc: Richmond, VA
hmm that part is already there... so maybe it fails in the part I told ya to add?<br /><br />
Code:
 2.1 Find:<br />// -----------------------------------------------------------------<br />// We need to know how many posts of this thread to display per page<br />   if ($fpart &lt;= 1) {<br />      $Totalgrab = $Totaldisplay;<br />   }<br />   else {<br />      $Startat = $Totaldisplay * ($fpart - 1);<br />      $Totalgrab = "$Startat, $Totaldisplay";<br />   }<br />   $Limit = "LIMIT $Totalgrab";<br />   if ($fpart == "all") {<br />      $Limit = "";<br />   }<br /><br />   $threadnumber = $Number;<br /><br />2.2 BELOW it ADD:<br />// Photopost Information Post Screens 1.0 - New Start<br />    $query = "<br />        SELECT B_PosterId<br />        FROM  {$config['tbprefix']}Posts<br />        WHERE B_Main  = $current<br />        $Viewable<br />        GROUP BY B_PosterId<br />    ";<br />    <br />    $sth = $dbh -&gt; do_query($query);<br />    $arrPosters = array();<br />    $strFilter = "";<br />    <br />    // Put all the unique ID's of the posters for this page in an array<br />    // and construct the filter for the Photopost database<br />    while (list($intPosterId) = $dbh-&gt;fetch_array($sth)) {<br />        $arrPosters["$intPosterId"] = 0;<br />        $strFilter .= "$intPosterId,";<br />    }<br />    <br />    // Now strip the last comma from the filter variable<br />    $strFilter = substr($strFilter, 0, -1);<br />    <br />    $PPLink = mysql_connect("{$config['PPost_Host']}:3306", "{$config['PPost_User']}", "{$config['PPost_Password']}", true) or <br />              die("Could not connect to PhotoPost host". mysql_error());<br />    <br />    mysql_select_db ("{$config['PPost_Database']}", $PPLink) or <br />    die ("Could not connect to PhotoPost database". mysql_error());<br />    <br />    $query = "SELECT userid, COUNT(id) <br />              FROM {$config['PPost_DBPrefix']}photos <br />              WHERE userid IN ($strFilter)<br />              GROUP BY userid ";<br />    <br />    // Do the query now<br />    $PPResult = mysql_query($query, $PPLink);<br />    <br />    // Now loop through the records and update the array<br />    while (list($intUser, $intCount) = mysql_fetch_array($PPResult)) {<br />        $arrPosters["$intUser"] = $intCount;<br />    }<br />    <br />    mysql_free_result($PPResult); <br />// Photopost Information Post Screens 1.0 - New End<br /> 
<br /><br />Just rechecked it's exactly what I have.. did you make sure you included the photopost database? did you create a file called configextras?
_________________________
Couchtomatoe - www.couch-tomatoe.cc
My abilities are for hire for installs, upgrades, custom themes and custom modifications.

Top
#263955 - 08/08/04 03:48 PM Re: Beta-[6.5] Photopost Information in Post Screens 2.0 [Re: 234234]
scroungr Offline
Old Hand

Registered: 10/17/03
Posts: 2409
Loc: Richmond, VA
if you make a configextras.php and include that in the ubbt.inc.php will make life easier when upgrading threads..
_________________________
Couchtomatoe - www.couch-tomatoe.cc
My abilities are for hire for installs, upgrades, custom themes and custom modifications.

Top
#263956 - 08/08/04 04:41 PM Re: Beta-[6.5] Photopost Information in Post Screens 2.0 [Re: 234234]
monkeyra Offline
Junior Member

Registered: 06/28/01
Posts: 363
Loc: uk
i didnt create a file called configextras, there wasnt any mention of it in the instructions.<br />have i downloaded an old version of this hack by chance?

Top
#263957 - 08/08/04 05:53 PM Re: Beta-[6.5] Photopost Information in Post Screens 2.0 [Re: Luka_dup1]
scroungr Offline
Old Hand

Registered: 10/17/03
Posts: 2409
Loc: Richmond, VA
possibly. does yours say version 2? I just checked it and updated it in case byut there was not much difference.. go download and see if it says to create a configextras.php file..
_________________________
Couchtomatoe - www.couch-tomatoe.cc
My abilities are for hire for installs, upgrades, custom themes and custom modifications.

Top
#263958 - 08/09/04 03:06 AM Re: Beta-[6.5] Photopost Information in Post Screens 2.0 [Re: 234234]
monkeyra Offline
Junior Member

Registered: 06/28/01
Posts: 363
Loc: uk
yeah, i've done that.<br />still getting the message though, and also in the profile (side of threads, under the avatar) i'm getting this.<br />// Photopost Information Post Screens 1.0 - New Start <br />// Photopost Information Post Screens 1.0 - New End <br />which appears one everyone who has photos in the gallery.

Top
#263959 - 08/09/04 07:33 AM Re: Beta-[6.5] Photopost Information in Post Screens 2.0 [Re: Luka_dup1]
scroungr Offline
Old Hand

Registered: 10/17/03
Posts: 2409
Loc: Richmond, VA
hmm then you are getting an older version cause I don't have <br /><br />// Photopost Information Post Screens 1.0 - New Start <br /><br />mine says<br /><br />// Photopost Information Post Screens 2.0 - New Start <br /><br />but not in the template which is where it would say that if it did.
_________________________
Couchtomatoe - www.couch-tomatoe.cc
My abilities are for hire for installs, upgrades, custom themes and custom modifications.

Top
#263960 - 08/09/04 07:41 AM Re: Beta-[6.5] Photopost Information in Post Screens 2.0 [Re: 234234]
monkeyra Offline
Junior Member

Registered: 06/28/01
Posts: 363
Loc: uk
i'll start again and rehack it, with the new version!<br />lol, could have sworn i had the recent one, i must have got confused somewhere.

Top
#263961 - 08/10/04 10:14 AM Re: Beta-[6.5] Photopost Information in Post Screens 2.0 [Re: Luka_dup1]
monkeyra Offline
Junior Member

Registered: 06/28/01
Posts: 363
Loc: uk
working a treat now!<br />I like this hack a lot, brilliant idea.<br />you think it could be amended to use with the photopost classifieds software?

Top
Page 1 of 2 1 2 >



Moderator:  Ian_W 
Latest Posts
[7.2.1] - Naked shoutbox
by bellaonline
05/05/12 05:00 PM
[7.x] Stop Forum Spam Integration v0.4
by bellaonline
05/05/12 03:53 PM
Shout Box

(Views)Popular Topics
Known public proxy servers 1689885
Integrated Index Page (IIP) 5.3.1 555705
Finished-[6.5.2] Games Arcade Deluxe v1.9 501236
Integrated Index Page (IIP) 5.1.1 415112
TLD Bv2.1 Released - Threads Links Directory 396822
[6.0x] Who's Online 4.0.0 [Finished] 389412
Finished-[6.5.1] Integrated Index Page (IIP) 6.5 330423
Q & A 298663
Slash UBB 266936
[6.3.x] [beta] Hit Hack 2.0 227970
Forum Stats
13621 Members
59 Forums
37191 Topics
295716 Posts

Max Online: 686 @ 06/28/07 07:04 AM

 

 

 
fusionbb message board php hacks